package com.syq.face.service;

import com.syq.face.model.AttendanceInfo;
import com.syq.face.model.JsonResult;

import java.util.List;

import retrofit2.Call;
import retrofit2.http.Body;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.GET;
import retrofit2.http.Header;
import retrofit2.http.Multipart;
import retrofit2.http.POST;
import retrofit2.http.Part;
import retrofit2.http.Url;

public interface FaceService {
    //    {"result":
//        {"face_token":"135328f28d80df38c3b20accea2d2ec2",
//        "location":
//            {"top":163.74,"left":277.7,"rotation":-6,"width":128,"height":129}
//            },
//        "log_id":2500125799410,
//        "error_msg":"SUCCESS",
//        "cached":0,
//        "error_code":0,
//        "timestamp":1636483570
//    }
//    {"result":null,
//     "log_id":3575001059920,
//     "error_msg":
//     "liveness check fail",
//     "cached":0,
//     "error_code":223120,
//     "timestamp":1636483679
//    }
    @FormUrlEncoded
    @POST("/fras/user/faceRecognition/")
    Call<JsonResult> searchFace(
            @Header("Authorization") String token,
            @Field("image") String image,
            @Field("attendanceId") String attendanceId);


}
